cmake_minimum_required(VERSION 3.5.1)


add_subdirectory( open_space_trajectory_generation )
add_subdirectory( open_space_trajectory_partition  )
add_subdirectory( path_time_heuristic )
add_subdirectory( piecewise_jerk_path )
add_subdirectory( piecewise_jerk_speed )


add_library( path_optimizer path_optimizer.cc  )
target_link_libraries( path_optimizer
Eigen3::Eigen
common::status
planning::path_decision
planning::reference_line_info
planning::path_data
planning::speed_data
task
planning::planning_gflags
planning::speed_limit
)


add_library( speed_optimizer  speed_optimizer.cc )
target_link_libraries( speed_optimizer 
Eigen3::Eigen
common::status
planning::path_decision
planning::reference_line_info
planning::path_data
planning::speed_data
task
planning::st_graph_data
planning::planning_gflags

)



add_library( trajectory_optimizer  trajectory_optimizer.cc )
target_link_libraries( trajectory_optimizer
open_space_trajectory_optimizer
open_space_trajectory_provider
Eigen3::Eigen
common::status
planning::planning_gflags
planning::discretized_trajectory
task
)



install(TARGETS path_optimizer
                trajectory_optimizer
                speed_optimizer
        EXPORT  apollo-export
        LIBRARY DESTINATION lib
        ARCHIVE DESTINATION lib
        RUNTIME DESTINATION bin
        INCLUDES DESTINATION .
        )